(function($){
    function formResult(data) {
        layer.closeAll();
        if(data.status != 10000) {
            layer.alert(data.errmsg, {icon: 5});
        } else {
            layer.confirm('添加成功！', {icon: 6, title:'系统提示', btn: ['继续添加','查看列表']}, function(index){
                location.reload(true);
            }, function(index){
                location.href = urlMap.bpTagList;
            });
        }
    }
    $(function(){
        window.formResult = formResult;
        $('#form_add').on('valid.form', function(e, form){
            layer.load();
            form.submit();
        });
    });
})(jQuery);